package com.example.shop.entity;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.List;

/**
 * Created by Administrator on 2016/3/15.
 */
public class LimitbuyEntity {

    /**
     * list_count : 1500
     * response : limitbuy
     * productlist : [{"id":"1","lefttime":"6000000","limitprice":"226.00","marketprice":"316.00","name":"金奇仕婴幼儿鳕鱼肝油III60粒*2","pic":"http://192.168.3.235/images/home/news/1.jpg","price":"226.00"},{"id":"2","lefttime":"6000000","limitprice":"96.00","marketprice":"130.80","name":"首儿促销装（复合锌维D钙冲剂（幼儿型）30袋+首儿鳕鱼肝油软胶囊60粒）","pic":"http://192.168.3.235/images/home/news/2.jpg","price":"96.00"},{"id":"3","lefttime":"6000000","limitprice":"25.00","marketprice":"56.00","name":"汤美天地\u201c母乳自然\u201d超薄抛弃式乳垫(36入装)","pic":"http://192.168.3.235/images/home/news/3.jpg","price":"25.00"},{"id":"4","lefttime":"6000000","limitprice":"272.50","marketprice":"419.00","name":"小白熊奶瓶消毒器HL-0681","pic":"http://192.168.3.235/images/home/news/4.jpg","price":"272.50"},{"id":"5","lefttime":"6000000","limitprice":"116.00","marketprice":"179.00","name":"新安怡四安士对装PES奶瓶(125ML)","pic":"http://192.168.3.235/images/home/news/5.jpg","price":"116.00"},{"id":"6","lefttime":"6000000","limitprice":"59.00","marketprice":"88.00","name":"特福芬混合水果茶（水果冲饮）","pic":"http://192.168.3.235/images/home/news/6.jpg","price":"59.00"},{"id":"7","lefttime":"6000000","limitprice":"96.00","marketprice":"200.00","name":"施巴婴儿泡泡浴露500ml","pic":"http://192.168.3.235/images/home/news/7.jpg","price":"96.00"},{"id":"8","lefttime":"6000000","limitprice":"109.50","marketprice":"298.00","name":"金朵朵JDuDu防水实用妈咪包四件套（花瑶卡其色）","pic":"http://192.168.3.235/images/home/news/8.jpg","price":"109.50"},{"id":"9","lefttime":"6000000","limitprice":"230.00","marketprice":"438.00","name":"NUK宽口奶瓶 妈咪包套装高级礼盒","pic":"http://192.168.3.235/images/home/news/9.jpg","price":"230.00"},{"id":"10","lefttime":"6000000","limitprice":"22.00","marketprice":"46.00","name":"婴之侣大屏软头电子体温计","pic":"http://192.168.3.235/images/home/news/10.jpg","price":"22.00"}]
     */

    private int list_count;
    private String response;
    /**
     * id : 1
     * lefttime : 6000000
     * limitprice : 226.00
     * marketprice : 316.00
     * name : 金奇仕婴幼儿鳕鱼肝油III60粒*2
     * pic : http://192.168.3.235/images/home/news/1.jpg
     * price : 226.00
     */

    private List<ProductlistEntity> productlist;

    public void setList_count(int list_count) {
        this.list_count = list_count;
    }

    public void setResponse(String response) {
        this.response = response;
    }

    public void setProductlist(List<ProductlistEntity> productlist) {
        this.productlist = productlist;
    }

    public int getList_count() {
        return list_count;
    }

    public String getResponse() {
        return response;
    }

    public List<ProductlistEntity> getProductlist() {
        return productlist;
    }

    public static class ProductlistEntity implements Parcelable {
        private String id;
        private String lefttime;
        private String limitprice;
        private String marketprice;
        private String name;
        private String pic;
        private String price;

        public void setId(String id) {
            this.id = id;
        }

        public void setLefttime(String lefttime) {
            this.lefttime = lefttime;
        }

        public void setLimitprice(String limitprice) {
            this.limitprice = limitprice;
        }

        public void setMarketprice(String marketprice) {
            this.marketprice = marketprice;
        }

        public void setName(String name) {
            this.name = name;
        }

        public void setPic(String pic) {
            this.pic = pic;
        }

        public void setPrice(String price) {
            this.price = price;
        }

        public String getId() {
            return id;
        }

        public String getLefttime() {
            return lefttime;
        }

        public String getLimitprice() {
            return limitprice;
        }

        public String getMarketprice() {
            return marketprice;
        }

        public String getName() {
            return name;
        }

        public String getPic() {
            return pic;
        }

        public String getPrice() {
            return price;
        }

        @Override
        public int describeContents() {
            return 0;
        }

        @Override
        public void writeToParcel(Parcel dest, int flags) {
            dest.writeString(this.id);
            dest.writeString(this.lefttime);
            dest.writeString(this.limitprice);
            dest.writeString(this.marketprice);
            dest.writeString(this.name);
            dest.writeString(this.pic);
            dest.writeString(this.price);
        }

        public ProductlistEntity() {
        }

        protected ProductlistEntity(Parcel in) {
            this.id = in.readString();
            this.lefttime = in.readString();
            this.limitprice = in.readString();
            this.marketprice = in.readString();
            this.name = in.readString();
            this.pic = in.readString();
            this.price = in.readString();
        }

        public static final Parcelable.Creator<ProductlistEntity> CREATOR = new Parcelable.Creator<ProductlistEntity>() {
            public ProductlistEntity createFromParcel(Parcel source) {
                return new ProductlistEntity(source);
            }

            public ProductlistEntity[] newArray(int size) {
                return new ProductlistEntity[size];
            }
        };
    }
}
